Skip to content

Conversation

@bmorris3
Copy link
Contributor

The astroquery.mast.MastMissions supports query_region and query_criteria with radius <= 0.5 * u.deg. The current uninformative error message when radius > 0.5 * u.deg comes from POST.

This PR adds the radius limitation to the docstrings, and raises an InvalidQueryError if radius > 0.5 * u.deg.

@bmorris3 bmorris3 force-pushed the mastmissions-radius-limit branch 2 times, most recently from 0204c54 to 941a111 Compare October 24, 2025 16:44
@codecov
Copy link

codecov bot commented Oct 24, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 71.48%. Comparing base (587ae55) to head (ff01e92).
⚠️ Report is 64 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3447      +/-   ##
==========================================
+ Coverage   71.31%   71.48%   +0.16%     
==========================================
  Files         234      234              
  Lines       20034    20096      +62     
==========================================
+ Hits        14287    14365      +78     
+ Misses       5747     5731      -16     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Contributor

@snbianco snbianco left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you so much for this PR! There are a few very minor things I commented on, but overall, this looks great.

CHANGES.rst Outdated
- Filtering by file extension or by a string column is now case-insensitive in ``MastMissions.filter_products``
and ``Observations.filter_products``. [#3427]

- Raise informative error if MastMissions query radius is too large. [#3447]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nitpick, but could you put MastMissions in double backticks? Just so users know that we're referring to a class.

Raises
------
InvalidQueryError
If the query radius is larger than the limit (30 arcminute).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be "30 arcminutes" in parentheses.

Raises
------
InvalidQueryError
If the query radius is larger than the limit (30 arcminute).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See above comment

@snbianco snbianco requested a review from bsipocz October 24, 2025 17:56
@snbianco snbianco added the mast label Oct 27, 2025
@bmorris3
Copy link
Contributor Author

Hi @bsipocz! Friendly ping.

@bsipocz
Copy link
Member

bsipocz commented Nov 17, 2025

I'm travelling quite a bit this autumn so things are slower than usual. This one is in the review queue, I'll get back to it once the other big ones are cleared.

@bmorris3
Copy link
Contributor Author

Great, thanks @bsipocz 😄

@bsipocz bsipocz added this to the 0.4.12 milestone Nov 21, 2025
Copy link
Member

@bsipocz bsipocz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will need a rebase, and I have one minor question, otherwise it's ready to go in.

Thanks!

Comment on lines +50 to +51
# maximum supported query radius
_max_query_radius = 30 * u.arcmin
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How will we notice if this changes on the server side?

@bsipocz bsipocz force-pushed the mastmissions-radius-limit branch from b208ae9 to ff01e92 Compare November 21, 2025 13:56
@bsipocz
Copy link
Member

bsipocz commented Nov 21, 2025

Well, I already did the rebase locally while testing this, so pushed that back and merging once CI is green.

@bsipocz bsipocz merged commit 026b051 into astropy:main Nov 21, 2025
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants